package com.imooc.reader.service;

import com.imooc.reader.entity.Evaluation;
import com.imooc.reader.entity.Member;
import com.imooc.reader.entity.MemberReadState;

public interface MemberService {

    public Member creatMember(String username, String password, String nickname);

    //登录校验
    public Member checkLogin(String username, String password);


    /**
     * 通过id获取该会员的阅读状态
     *
     * @param memberId
     * @param bookId
     * @return
     */
    public MemberReadState selectStateById(Long memberId, Long bookId);

    /**
     * 更新阅读的状态
     */
    public MemberReadState updateMemberState(Long memberId, Long bookId, Integer readState);

    /**
     * 添加评论功能
     */

    public Evaluation insertScore(Long bookId, Long memberId, Integer score, String content);


}
